import mysql from "mysql2/promise"
// const mysql = require('mysql2');

// console.log(mysql)
const db = await mysql.createConnection({
  host: "localhost",
  user: "root",
  database: "test",
  password: "52567@cSz",
})

try {
  const [results, fields] = await db.query("SELECT * FROM users")
  console.log(results)
  console.log(fields)
} catch (err) {
  console.log(err)
}
